<template>
  <div class="bg">
    <!-- 头部 -->
    <el-breadcrumb separator-class="el-icon-arrow-right" style="padding:3vh 0;font-size:1rem">
      <el-breadcrumb-item :to="{ path: '/news' }">新闻管理</el-breadcrumb-item>
      <el-breadcrumb-item>编辑新闻</el-breadcrumb-item>
    </el-breadcrumb>
    <!-- 表格 -->
    <el-form label-width="110px" :model="repairForm" ref="repairFormRef" :rules="repairFormRules" size="small">
      <el-form-item label="选择单位" prop="a" style="width:50%">
        <el-select v-model="repairForm.a" style="width:100%">
          <el-option label="选项1" value="1"></el-option>
          <el-option label="选项2" value="2"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="选择栏目" prop="b" style="width:50%">
        <el-select v-model="repairForm.b" style="width:100%">
          <el-option label="选项1" value="1"></el-option>
          <el-option label="选项2" value="2"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="新闻标题" prop="c" style="width:50%">
        <el-input v-model="repairForm.c" style="width:100%"></el-input>
      </el-form-item>
      <el-form-item label="新闻内容描述" prop="d" style="width:50%">
        <el-input v-model="repairForm.d" type="textarea" :rows="1" style="width:100%"></el-input>
      </el-form-item>
      <el-form-item label="新闻内容" prop="e" style="width:100%;color:#000">
        <vue-ueditor-wrap v-model="msg" :config="editorConfig" editor-id="editor-demo-01"></vue-ueditor-wrap>
      </el-form-item>
      <el-form-item label="作者" prop="f" style="width:50%">
        <el-input v-model="repairForm.f" style="width:100%"></el-input>
      </el-form-item>
      <el-form-item label="是否推荐" prop="g" style="width:100%">
        <div class="row-1-border">
          <el-radio v-model="repairForm.g" label="1" size="mini">是</el-radio>
          <el-radio v-model="repairForm.g" label="2" size="mini">否</el-radio>
        </div>
      </el-form-item>
      <div style="padding-left:2vw">
        <el-button type="primary">保存</el-button>
        <el-button type="info">返回</el-button>
      </div>
    </el-form>
  </div>
</template>

<script>
import moment from "moment";

export default {
  data() {
    return {
      repairForm: {},
      msg: "",
      editorConfig: {
        autoHeightEnabled: false,
        initialFrameHeight: 400,
        initialFrameWidth: "100%",
        UEDITOR_HOME_URL: "/UEditor/", // 访问 UEditor 静态资源的根路径
        serverUrl: "", // 服务端接口//ueditor.szcloudplus.com/cos
        enableAutoSave: true, // 开启从草稿箱恢复功能需要手动设置固定的 editorId，否则组件会默认随机一个，如果页面刷新，下次渲染的时候 editorId 会重新随机，导致无法加载草稿箱数据
      },
    };
  },
  mounted() {},
  beforeUnmount() {},
  methods: {},
};
</script>


<style lang="less" scoped>
@import "../../../OperaManage/opera.less";

.bg {
  width: 100%;
  height: 100%;
  padding: 0 20px;
  background: url("../../../../assets/img/bj.jpg") no-repeat;
}

.row-1-border {
  // height: 31px;
  // border: 1px solid #72aeff;
  // border-radius: 5px;
  // padding: 0 0 0 35px;
}

/deep/ .el-breadcrumb__item .el-breadcrumb__inner {
  color: #fff;
}
</style>